<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <title>我的收货地址</title>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=no">
    <meta name="format-detection" content="telephone=no">
    <link rel="stylesheet" href="../../css/aui.css">
    <link rel="stylesheet" href="../../css/common.css">
    <script type="text/javascript" src="../../script/api.js"></script>
    <script language="JavaScript" src="../../script/vue.js"></script>
    <script language="JavaScript" src="../../script/common.js"></script>
    <style>
        .bgcolor-white {
            background-color: #fff;
            color: #151516;
            font-size: 0.6rem;
        }

        .addressitem {
            line-height: 1.5rem;
            padding: 0.3rem;
            position: relative;
        }

        .addressitem .address-item-choose-btn {
            position: absolute;
            display: inline-block;
            width: 2rem;
            height: 1.2rem;
            top: 25px;
            right: 15px;
            line-height: 1.2rem;
            font-size: 0.7rem;
            color: #58595b;
            text-align: center;
            border: 1px solid #58595b;
            border-radius: 5px;
        }

        .addressop {
            position: relative;
            display: flex;
            -webkit-justify-content: space-between;
            justify-content: space-between;
            font-size: 0.6rem;
        }

        .default-btn {
            color: #e02e24;
        }

        .common-btn {
            color: #9c9c9c;
        }

        .common-btn span {
            position: absolute;
            top: -0.1rem;
            left: 1rem;
            display: inline-block;
        }

        .aui-opbtn span {
            display: inline-block;
        }

        .rediobtn-red {
            border: 1px solid #e02e24;
            font-size: 0.6rem;
            background-color: #e02e24;
            border-radius: 50%;
            color: #fff;
        }

        .radiobtn-hui {
            display: inline-block;
            content: " ";
            font-size: 0.6rem;
            width: 0.8rem;
            height: 0.8rem;
            border: 1px solid #d9d9d9;
            border-radius: 50%;
            color: #fff;
        }

        .addressop .aui-opbtn {
            display: inline-block;
            margin-left: 0.5rem;
        }

        .address-box .addbtn {
            text-align: center;
            background-color: #e02e24;
            width: 60%;
            margin: 0.5rem auto;
            border-radius: 0.2rem;
            line-height: 1.5rem;
            color: #fff;
        }
    </style>
</head>

<body>
<div id="addressbox">
  <header class="aui-bar aui-bar-nav" id="header">
      <a class="aui-pull-left aui-btn" onclick="goback();">
          <span class="aui-iconfont aui-icon-left"></span>
      </a>
      <div class="aui-title">地址列表</div>
  </header>
</div>

    <script language="javascript">
       function goback()
       {
         if(vm.postparam.product_id>0){
           $page.openwin('product_checkorder','../product/checkorder.html',vm.postparam);
         }else{
           api.closeToWin({
               name: 'root'
           });
         }


       }

        var vm = new Vue({
            el: '#addressbox',
            data: {
                postparam: {
                    product_id: 0,
                    sku_id: 0,
                    buymod: '',
                    orderno: '',
                    buynum: 0,
                    token:$api.getStorage('token'),
                    addressid: 0
                },


            },
            methods: {
                openaddress: function() {
                   var headerh = $api.dom("header").offsetHeight;
                    $page.openfrm('home_address_frm', './address_frame.html',{x:0,y:headerh,h:api.winHeight-headerh}, this.postparam,false,true);
                },

            }
        });
        apiready=function(){
       
          var pageParam = api.pageParam;
          vm.postparam.product_id = pageParam.product_id;
          vm.postparam.sku_id = pageParam.sku_id;
          vm.postparam.buymod = pageParam.buymod;
          vm.postparam.orderno = pageParam.orderno;
          vm.postparam.buynum = pageParam.buynum;

          $page.init();

          vm.openaddress();
        }

    </script>

</body>

</html>
